﻿import com.gamemeal.physics.IForce;
import com.gamemeal.physics.Particle;

/**
 * @author Colin Leung
 */
class com.gamemeal.physics.SimpleFractionForce implements IForce {
	private var f:Number;
	public function SimpleFractionForce(arg:Number){
		f = (arg==undefined)?0.9:arg;
	}

	public function apply(p : Particle, t : Number) {
		p.vi.length=p.vi.length*f;
		p.ω = p.ω*f;
	}
}